<?php

use Asf\Support\Env;

define('APP_PATH', dirname(__DIR__));

\Swoole\Runtime::enableCoroutine(SWOOLE_HOOK_ALL);

$builder = new DI\ContainerBuilder();
$builder->addDefinitions(APP_PATH . '/config/definitions.php');

$container = $builder->build();

//禁用$_ENV
Env::disablePutenv();

Dotenv\Dotenv::create(
    Env::getRepository(),
    APP_PATH
)->safeLoad();

return $container;